#ifndef __Property_H__
#define __Property_H__
#include "cocos2d.h"
#include "ui/UILoadingBar.h"
#include <string>
using namespace std;
using namespace cocos2d::ui;
USING_NS_CC;

enum{
	HP,
	MP,
	SHIELD,
};
class CProperty : public Node
{
public:
	CProperty();
	~CProperty();
	CREATE_FUNC(CProperty);
	virtual bool init();
	void refresh(int value,int sort);

private:
	int m_nMaxHp;
	int m_nMaxMp;
	int m_nMaxShield;

	LoadingBar* pHpBar;
	Label* pHpLabel;

	LoadingBar* pShieldBar;
	Label* pShieldLabel;

	LoadingBar* pMpBar;
	Label* pMpLabel;


	Sprite* m_pBox;
	LoadingBar* initSlider(string picName, Vec2 pos, int value);
	Label* initLabel(int value, Vec2 pos);
};



#endif